package com.lone.design.pattern.creational.builder;

/**
 * @author Lone
 * @date 2021/9/24 15:54 周五
 */
public class Director {
    // 声明builder类型变量
    private Builder builder;

    public Director(Builder builder) {
        this.builder = builder;
    }

    public Bike construct() {
        builder.buildFrame();
        builder.buildSeat();
        return builder.createBike();
    }
}
